<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<import type="js" file="js.jquery" />
<import type="js" file="js.common" />
<import type="css" file="css.global" />
<import type="css" file="css.form" />
</head>
<body>
<div class="search">
	<input type="button" value="添加" class="button" onclick="add()" >
</div>
<div class="list">
<table class="stripe" cellspacing="0">
    <thead>
        <tr>
        	<th style="min-width: 30px;"><input type="checkbox" name="checkid" onclick="if(this.checked==true) { checkAll('key[]'); } else { clearAll('key[]'); }" ></th>
            <th width="60%">标题</th>
            <th width="12%">发送人</th>
            <th width="12%">时间</th>
            <th width="14%">操作</th>
        </tr>
    </thead>
 
    <tbody>
    <volist name="data" id="vo" empty="$empty">
        <tr>
            <td><input type="checkbox" name="key[]" value="{$vo.id}"></td>
            <td><a href="javascript:void(0);" onclick="view({$vo.id});">{$vo.title}</a></td>
            <td>{$vo.author}</td>
            <td>{$vo.create_time|mb_substr=0,10,'utf-8'}</td>
            <td><a href="javascript:void(0);" onclick="edit({$vo.id})" title="编辑">编辑</a>&nbsp;|&nbsp;<a href="javascript:void(0);" onclick="del({$vo.id})" title="删除">删除</a></td>
        </tr>
    </volist>
    </tbody>
</table>
</div>
<div class="page">{$page}</div>
</body>
</html>
<script language="javascript">
$(document).ready(function(){  
	$(".stripe tr").mouseover(function(){    
	  $(this).addClass("over");}).mouseout(function(){   
			$(this).removeClass("over");}) 
  	$(".stripe tr:even").addClass("alt");
});   
function view(id){
	window.location="__APP__/Circular/view?id="+id;
}

function edit(id){
	window.location="__APP__/Circular/edit?id="+id;
}

function add(){
	window.location="__APP__/Circular/add";
}

function del(id) {
	if (confirm("真的要删除吗？")){
		$.get("__APP__/Circular/delete?id="+id, function(result){
			location.reload();
		});
	}else{
		return false;
	}
}
</script>  